import request from '@/utils/request'

//注册接口
export const GetDriverService = () => {
  return request.get('/driver/list')
}

export const AddDriverService = (data) => {
  return request.post('/driver/save', data)
}

export const EditDriverService = (data) => {
  return request.put('/driver/update', data)
}

export const DelDriverService = (id) => {
  return request.delete('/driver/delete', {
    params: { id }
  })
}

export const GetDriverDetailService = (id) => {
  return request.get('/driver/findById', {
    params: { id }
  })
}

export const GetDriverFindByQueryService = (query) => {
  return request.get('/driver/findByName', {
   params: {query}
  })
}
